#ifndef XLIGHT
#define XLIGHT
#include "../XModEngine/XObject.h"
#include "../XModEngine/vector.h"
#include "XFormat.h"
using namespace XEFMT;
class XM_ENTRY XLight : public XObject
{
protected:
	LightType m_type;
	Color m_Ambient, m_Specular, m_Diffuse;
	Vector3 m_Position,m_Direction;
	float m_Range, m_FallOff, m_A1, m_A2, m_A3, m_Theta, m_Phi;
	int m_lightIndex;
public:
	XLight();
	~XLight();
	void SetLightType(LightType light);
	LightType GetLightType();
	void SetAmbient(Color ambient);
	void SetDiffuse(Color diffuse);
	void SetSpecular(Color specular);
	Color GetAmbient();
	Color GetDiffuse();
	Color GetSpecular();
	void SetPosition(Vector3 position);
	Vector3 GetPosistion();
	void SetDirection(Vector3 direction);
	Vector3 GetDirection();
	void SetRange(float range);
	float GetRange();
	void SetFallOff(float falloff);
	float GetFallOff();
	void SetAttenuation(int n_a,float a);
	float GetAttenuation(int n_a);
	void SetTheta(float theta);
	float GetTheta();
	void SetPhi(float phi);
	float GetPhi();
	void SetLightIndex(int index);
	int GetLightIndex();
};
#endif

